#pragma once
#include <fstream>
#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include "smart_car.h"
#include "student.h"

using namespace std;

class FileManager {
public:
    /**
     * @brief 将小车信息保存为.csv文件
     * 保存成功返回1，失败返回-1
     * @param fileName 文件名
     */
    int saveToFile(string fileName, const vector<SmartCar> cars);
    /**
     * @brief Get the File Info object
     * 
     * @return vector<SmartCar>& 
     */
    vector<SmartCar>& getFileInfo();

private:
    vector<SmartCar> m_smartCarsWithStu;
    string m_fileName;
};